<admintpl file="header" />
</head>
<body>
	<div class="wrap js-check-wrap">
		<ul class="nav nav-tabs">
			<li><a href="{:U('Activity/Adminactivity/lists')}">活动列表</a></li>
			<li class="active"><a href="javascript:;">订单列表</a></li>
		</ul>
		<form class="well form-search" method="post" action="{:U('Activity/Adminactivity/order_lists')}">
			<input type="hidden" name="id" value="{$act_id}">
            订单状态：
			<select name="status">
				<option value="0">请选择订单状态</option>
				<volist name="order_status" id="vo">
					<option value="{$key}" {$status == $key ? 'selected' : ''}>{$vo}</option>
				</volist>
			</select>

			<input type="submit" class="btn btn-primary" value="搜索" />
			<a class="btn btn-danger" href="{:U('Activity/Adminactivity/order_lists')}">清空</a>
		</form>


		<form class="js-ajax-form" action="" method="post">
			<table class="table table-hover table-bordered table-list">
				<thead>
					<tr>
						<th width="30">ID</th>
						<th width="150">用户名</th>
                        <th width="50">头像</th>
						<th width="300">票种名称</th>
						<th width="150">票价</th>
						<th width="150">数量</th>
						<th width="150">付款状态</th>
						<th width="150">退款状态</th>
						<th width="150">下单时间</th>
					</tr>
				</thead>
				<foreach name="lists" item="vo">
				<tr>
                    <td>{$vo.id}</td>
					<td>{$vo.user_nicename}</td>
					<td><img style="width: 35px;height: 35px;border-radius: 50%;border: transparent;" src="{:sp_get_user_avatar_url($vo['avatar'])}?t={:time()}"></td>
					<td>{$vo.name}</td>
					<td>{$vo.price}</td>
					<td>{$vo.goods_num}</td>
					<td>{$order_status[$vo['status']]}</td>
					<td>
						<php>
							if ($vo['refund_status'] == 0) {
								$refund_status = '正常';
							} elseif ($vo['refund_status'] == 1) {
								$refund_status = '申请中';
							} elseif ($vo['refund_status'] == 2) {
								$refund_status = '已退款';
							} else {
								$refund_status = '退款失败';
							}
						</php>
						{$refund_status}
					</td>
					<td>{:date('Y-m-d H:i:s', $vo['created_at'])}</td>
				</tr>
				</foreach>
			</table>
			<div class="pagination">{$page}</div>
		</form>
	</div>
	<script src="__PUBLIC__/js/common.js"></script>
</body>
</html>